<script src="{{ site.baseurl }}/assets/javascripts/jquery.fullPage.min.js"></script>
<script src="{{ site.baseurl }}/assets/javascripts/jquery.easing.min.js"></script>
<script>
    $(document).ready(function () {
        $.fn.fullpage({
            anchors: ['fmain', 'life', 'memory', 'continue'],
            css3: true,
            fixedElements: '.site-notice',
            menu: '#menu',
            navigation: true,
            navigationPosition: 'right',
            resize: false,
            scrollingSpeed: 500,

            // afterLoad: function (anchorLink, index) {
            //     if (index === 1) {
            //         $('#section0 .headings, #section0').removeClass('hidden').addClass('fadeInDown');
            //         $('.btn-continue').removeClass('hidden').addClass('bounce');
            //     }
            //     if (index === 2) {
            //         $('#section1 h1, #section1 .social-links').removeClass('hidden').addClass('fadeInUp');
            //     }
            // },

            // onLeave: function (index, direction) {
            //     if (index == 1 && direction == 'down') {
            //         $('#section0 .headings, #section0 .btn-continue').addClass('hidden').removeClass('bounce fadeInDown fadeInLeft');
            //     }
            //     if (index == 2 && direction == 'up') {
            //         $('#section1 h1, #section1 .social-links').addClass('hidden').removeClass('fadeInUp');
            //     }
            // }
        });
    });

</script>

{% if site.google_analytics %}
<script>
$(document).on('click', '[class*="btn"]', function(event) {
    sendGaEvent('Home', 'Click', event.currentTarget);
});
</script>
{% endif %}
